PreviousNextTracker indexSee it online !

(4/34) 5 - $HOME problem on Win98

Versions:
Win98 SE
JEdit 4.0.3

Problem:
On Windows 98 systems, "open with JEdit" fails if
$HOME is set to anything other than the Windows
installation. There may be other associated problems,
but this is the simplest.
This causes clashes if you are using cygwin.

Reason: the server file used for security is put in
the .jedit directory. In jEdit.java, where this is initially
created, the settings directory used is specified by line
108:
MiscUtilities.constructPath(System.getProperty
("user.home"),".jedit");
On Win98, this goes to the Windows install.

In RegistryParser.cpp, where it is looked for when "Open
With" tries to connect to the server, the settings
directory used is specified by:
else // Win95/98/Me (lines 152-156)
{
if(0 == GetEnvironmentVariable("HOME",
szServerPath, MAX_PATH))

GetEnvironmentVariable("WINDIR",
szServerPath, MAX_PATH);
}

Result: open with looks in the wrong place for the server
file, fails to find it, and therefore doesn't load your file.

Workaround:
Use your windows install directory as $HOME, and point
there.

Fix: Change RegistryParser.cpp to look in WINDIR
directly, as on these systems Java user.home will be
$WINDIR not $HOME (AFAIK). So then:
else // Win95/98/Me (lines 152-155)
{
GetEnvironmentVariable("WINDIR",
szServerPath, MAX_PATH);
}


Submitted andrewlang - 2002-09-25 08:27:36 Assigned
Priority 5 Labels
Status open Group None
Resolution None

Comments

2003-06-04 05:34:14
spestov

- **labels**: 102668 -->